# -*- coding:UTF8 -*-
# author:叶向平
# date:2020/4/5
# IDE:PyCharm

import requests

# client_id 为官网获取的AK， client_secret 为官网获取的SK
host = 'https://aip.baidubce.com/oauth/2.0/token?grant_type=client_credentials&client_id=q0bGd2rckQ3QwoniWBVS3Gm3&client_secret=etx58m2EwrzPSKSF8hxEiRyj2GmRGO7g'
response = requests.get(host)
if response:
    print(response.json()['access_token'])
